﻿<%@ Page Language="vb" AutoEventWireup="false" MasterPageFile="~/admin/ajax_view_page.Master" CodeBehind="Links.aspx.vb" Inherits="Web.Links" 
    title="友情链接" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ MasterType VirtualPath="~/admin/ajax_view_page.Master" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<asp:Content ID="Content1" ContentPlaceHolderID="comCont" runat="server">
<asp:UpdatePanel ID="dgUpPal" runat="server" UpdateMode="Conditional">
                <ContentTemplate>
                
         <!-- 按钮 -->
         <div class="anniu_x">
                    <asp:Button runat="server" CssClass="btn" Text="查询" ID="searchBtn"/>
                    <asp:Button runat="server" CssClass="btn" ID="addbtn" Text="添加" ToolTip="添加新的数据" OnClick="addbtn_Click" />
            <asp:Button ID="delBtn" runat="server" CssClass="btn" Text="删除" ToolTip="删除本页选择数据" OnClientClick="if(confirm('是否确认删除所选数据?')!=true) return false;" />
                    <asp:Button ID="outbtn" CssClass="btn" runat="server" OnClick="outbtn_Click" Text="导出" />
                 </div>
               <!-- 按钮 -->     
              

<!-- 表单式DgGrid -->
   
            <asp:GridView ID="dgGrid" runat="server" width="100%" PageSize="100" AutoGenerateColumns="False" CellPadding="3" GridLines="Horizontal" BackColor="White" BorderColor="White" BorderStyle="None" BorderWidth="1px" DataKeyNames="ay01" ShowFooter="True">
            <FooterStyle cssclass="footer" />
            <RowStyle  cssclass="row" />   
            <SelectedRowStyle cssclass="xuanzhong" />
            <PagerStyle cssclass="pages"/>
            <AlternatingRowStyle  cssclass="row2" />
            <HeaderStyle cssclass="header" />
            <Columns>
                <asp:TemplateField HeaderText="操作">
                    <HeaderTemplate>
                        <asp:CheckBox ID="opChk" runat="server" AutoPostBack="True" OnCheckedChanged="opChk_CheckedChanged"
                            ToolTip="全选/反选 本页所有数据" />
                            </HeaderTemplate>
                     <HeaderStyle Width="10px" HorizontalAlign="Right" />
                    <ItemTemplate>
                        <asp:CheckBox ID="DelChk" runat="server" />
                    		</ItemTemplate>
                </asp:TemplateField>
                <asp:HyperLinkField DataNavigateUrlFields="ay01" DataNavigateUrlFormatString="linksin.aspx?id={0}"
                    DataTextField="ay02" HeaderText="标题" />
                <asp:BoundField DataField="ay05" HeaderText="顺序">
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:TemplateField HeaderText="状态">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("ay06") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# IIF(eval("ay06")=1,"启用","禁用") %>'></asp:Label>
                    </ItemTemplate>
                    <ItemStyle HorizontalAlign="Center" />
                </asp:TemplateField>

            				</Columns>
        						</asp:GridView>
        						<div class="neirong1"><webdiyer:aspnetpager PageSize="30" id="artPage" runat="server" AlwaysShow="True" ShowCustomInfoSection="Left" UrlPaging="True" PagingButtonLayoutType="Span" PrevPageText="上一页" CssClass="paginator" CurrentPageButtonClass="cpb" FirstPageText="首页" LastPageText="尾页" NextPageText="下一页" CustomInfoTextAlign="Left" LayoutType="Table" AlwaysShowFirstLastPageNumber="True" CustomInfoHTML="" NumericButtonCount="5" PageIndexBoxType="DropDownList" ShowPageIndexBox="Auto" SubmitButtonText="转到"></webdiyer:aspnetpager></div>

<!-- 表单式DgGrid -->

<!-- 查询隐藏层 -->

<cc1:ModalPopupExtender ID="modelPop" runat="server" X="100" Y="50" DropShadow="true" Drag="false" TargetControlID="searchBtn" OkControlID="HiddenField1" 
                            CancelControlID="cancelbtn" PopupControlID="txtPal" BackgroundCssClass="bg_x" > 
                    </cc1:ModalPopupExtender>
                    
                     <asp:HiddenField id="HiddenField1" runat="server" value="1"/>
                     
                    <asp:Panel ID="txtPal" runat="server">
                       <div class="search_x">选择查询条件</div>
<div class="search_y"><table border="1" style="border-collapse:collapse;background-color:#F2F2F2;" cellpadding="2" cellspacing="2" >
            
            <tr>
                <td class="tab_l">
                    标题:
                </td>
                <td class="tab_l3"><asp:TextBox runat="server" ID="ay02" Columns="10" /></td>
            </tr>
        </table>
        <div class="center"><asp:Button ID="okbtn" runat="server" Text="确定" CssClass="btn"  OnClick="okbtn_Click" />&nbsp;
                    <asp:Button ID="cancelbtn" runat="server" Text="取消" CssClass="btn"  /></div></div> 
                     </asp:Panel>
                     
<!-- 查询隐藏层 -->

<!-- 数据导出隐藏层 -->            
                     
                     <cc1:ModalPopupExtender ID="outPop" runat="server" X="150" Y="100"
                        DropShadow="true" Drag="false" TargetControlID="HiddenField1" OkControlID="HiddenField1" CancelControlID="HiddenField1" PopupControlID="Panel1" PopupDragHandleControlID="Panel2"  BackgroundCssClass="bg_x"> 
                    </cc1:ModalPopupExtender>
                    
                    <asp:Panel ID="Panel1" runat="server">
<div class="search_x">数据导出</div>
                        
                        <div class="search_y">
<table border="1" style="border-collapse:collapse;background-color:#F2F2F2;" cellpadding="2" cellspacing="2" >
            
            <tr>
                <td class="tab_l4"><asp:HyperLink ID="downlnk" runat="server">正在导出,请稍候...</asp:HyperLink></td>
            </tr>

            <tr>
                <td class="tab_l4">
                    <asp:Button ID="outcancelbtn" runat="server" Text="关闭" CssClass="btn" OnClick="outcancelbtn_Click1" /></td>
            </tr>
        </table>
                        </div> 
                     </asp:Panel>
                </ContentTemplate>
            </asp:UpdatePanel>

<!-- 数据导出隐藏层 --> 

</asp:Content>

